<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.14"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>Qwt User&#39;s Guide: QwtOHLCSample Class Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtreedata.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
  $(document).ready(initResizable);
/* @license-end */</script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname">Qwt User&#39;s Guide
   &#160;<span id="projectnumber">6.1.4</span>
   </div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.14 -->
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
var searchBox = new SearchBox("searchBox", "search",false,'Search');
/* @license-end */
</script>
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(function() {
  initMenu('',true,false,'search.php','Search');
  $(document).ready(function() { init_search(); });
});
/* @license-end */</script>
<div id="main-nav"></div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
      <div id="nav-sync" class="sync"></div>
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(document).ready(function(){initNavTree('class_qwt_o_h_l_c_sample.html','');});
/* @license-end */
</script>
<div id="doc-content">
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div class="header">
  <div class="summary">
<a href="#pub-methods">Public Member Functions</a> &#124;
<a href="#pub-attribs">Public Attributes</a> &#124;
<a href="class_qwt_o_h_l_c_sample-members.html">List of all members</a>  </div>
  <div class="headertitle">
<div class="title">QwtOHLCSample Class Reference</div>  </div>
</div><!--header-->
<div class="contents">

<p>Open-High-Low-Close sample used in financial charts.  
 <a href="class_qwt_o_h_l_c_sample.html#details">More...</a></p>

<p><code>#include &lt;<a class="el" href="qwt__samples_8h_source.html">qwt_samples.h</a>&gt;</code></p>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-methods"></a>
Public Member Functions</h2></td></tr>
<tr class="memitem:ad4056581f619e0a36d854fc5bb4341ef"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_o_h_l_c_sample.html#ad4056581f619e0a36d854fc5bb4341ef">QwtOHLCSample</a> (double <a class="el" href="class_qwt_o_h_l_c_sample.html#a7d457c0a7d71f90539bf6233a19c1df4">time</a>=0.0, double <a class="el" href="class_qwt_o_h_l_c_sample.html#a71b133fe8f7676b2ff7b17e39d669f95">open</a>=0.0, double <a class="el" href="class_qwt_o_h_l_c_sample.html#a4b23c1c6250364d4c58b6fc23ac1cdff">high</a>=0.0, double <a class="el" href="class_qwt_o_h_l_c_sample.html#aedac8489a18dfae092c010360c53ad7d">low</a>=0.0, double <a class="el" href="class_qwt_o_h_l_c_sample.html#a7627b9a618065a82e96e651406f4fac4">close</a>=0.0)</td></tr>
<tr class="separator:ad4056581f619e0a36d854fc5bb4341ef"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a8e282be32be601a1ed3c725cbe614fa9"><td class="memItemLeft" align="right" valign="top"><a class="el" href="class_qwt_interval.html">QwtInterval</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_o_h_l_c_sample.html#a8e282be32be601a1ed3c725cbe614fa9">boundingInterval</a> () const</td></tr>
<tr class="memdesc:a8e282be32be601a1ed3c725cbe614fa9"><td class="mdescLeft">&#160;</td><td class="mdescRight">Calculate the bounding interval of the OHLC values.  <a href="#a8e282be32be601a1ed3c725cbe614fa9">More...</a><br /></td></tr>
<tr class="separator:a8e282be32be601a1ed3c725cbe614fa9"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a5656375ea78ab080d53114ab80aa3934"><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_o_h_l_c_sample.html#a5656375ea78ab080d53114ab80aa3934">isValid</a> () const</td></tr>
<tr class="memdesc:a5656375ea78ab080d53114ab80aa3934"><td class="mdescLeft">&#160;</td><td class="mdescRight">Check if a sample is valid.  <a href="#a5656375ea78ab080d53114ab80aa3934">More...</a><br /></td></tr>
<tr class="separator:a5656375ea78ab080d53114ab80aa3934"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-attribs"></a>
Public Attributes</h2></td></tr>
<tr class="memitem:a7d457c0a7d71f90539bf6233a19c1df4"><td class="memItemLeft" align="right" valign="top">double&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_o_h_l_c_sample.html#a7d457c0a7d71f90539bf6233a19c1df4">time</a></td></tr>
<tr class="separator:a7d457c0a7d71f90539bf6233a19c1df4"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a71b133fe8f7676b2ff7b17e39d669f95"><td class="memItemLeft" align="right" valign="top"><a id="a71b133fe8f7676b2ff7b17e39d669f95"></a>
double&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_o_h_l_c_sample.html#a71b133fe8f7676b2ff7b17e39d669f95">open</a></td></tr>
<tr class="memdesc:a71b133fe8f7676b2ff7b17e39d669f95"><td class="mdescLeft">&#160;</td><td class="mdescRight">Opening price. <br /></td></tr>
<tr class="separator:a71b133fe8f7676b2ff7b17e39d669f95"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a4b23c1c6250364d4c58b6fc23ac1cdff"><td class="memItemLeft" align="right" valign="top"><a id="a4b23c1c6250364d4c58b6fc23ac1cdff"></a>
double&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_o_h_l_c_sample.html#a4b23c1c6250364d4c58b6fc23ac1cdff">high</a></td></tr>
<tr class="memdesc:a4b23c1c6250364d4c58b6fc23ac1cdff"><td class="mdescLeft">&#160;</td><td class="mdescRight">Highest price. <br /></td></tr>
<tr class="separator:a4b23c1c6250364d4c58b6fc23ac1cdff"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aedac8489a18dfae092c010360c53ad7d"><td class="memItemLeft" align="right" valign="top"><a id="aedac8489a18dfae092c010360c53ad7d"></a>
double&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_o_h_l_c_sample.html#aedac8489a18dfae092c010360c53ad7d">low</a></td></tr>
<tr class="memdesc:aedac8489a18dfae092c010360c53ad7d"><td class="mdescLeft">&#160;</td><td class="mdescRight">Lowest price. <br /></td></tr>
<tr class="separator:aedac8489a18dfae092c010360c53ad7d"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a7627b9a618065a82e96e651406f4fac4"><td class="memItemLeft" align="right" valign="top"><a id="a7627b9a618065a82e96e651406f4fac4"></a>
double&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_o_h_l_c_sample.html#a7627b9a618065a82e96e651406f4fac4">close</a></td></tr>
<tr class="memdesc:a7627b9a618065a82e96e651406f4fac4"><td class="mdescLeft">&#160;</td><td class="mdescRight">Closing price. <br /></td></tr>
<tr class="separator:a7627b9a618065a82e96e651406f4fac4"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<div class="textblock"><p>Open-High-Low-Close sample used in financial charts. </p>
<p>In financial charts the movement of a price in a time interval is often represented by the opening/closing prices and the lowest/highest prices in this interval.</p>
<dl class="section see"><dt>See also</dt><dd><a class="el" href="class_qwt_trading_chart_data.html">QwtTradingChartData</a> </dd></dl>
</div><h2 class="groupheader">Constructor &amp; Destructor Documentation</h2>
<a id="ad4056581f619e0a36d854fc5bb4341ef"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ad4056581f619e0a36d854fc5bb4341ef">&#9670;&nbsp;</a></span>QwtOHLCSample()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">QwtOHLCSample::QwtOHLCSample </td>
          <td>(</td>
          <td class="paramtype">double&#160;</td>
          <td class="paramname"><em>t</em> = <code>0.0</code>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">double&#160;</td>
          <td class="paramname"><em>o</em> = <code>0.0</code>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">double&#160;</td>
          <td class="paramname"><em>h</em> = <code>0.0</code>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">double&#160;</td>
          <td class="paramname"><em>l</em> = <code>0.0</code>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">double&#160;</td>
          <td class="paramname"><em>c</em> = <code>0.0</code>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Constructor</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">t</td><td>Time value </td></tr>
    <tr><td class="paramname">o</td><td>Open value </td></tr>
    <tr><td class="paramname">h</td><td>High value </td></tr>
    <tr><td class="paramname">l</td><td>Low value </td></tr>
    <tr><td class="paramname">c</td><td>Close value </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<h2 class="groupheader">Member Function Documentation</h2>
<a id="a8e282be32be601a1ed3c725cbe614fa9"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a8e282be32be601a1ed3c725cbe614fa9">&#9670;&nbsp;</a></span>boundingInterval()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="class_qwt_interval.html">QwtInterval</a> QwtOHLCSample::boundingInterval </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Calculate the bounding interval of the OHLC values. </p>
<p>For valid samples the limits of this interval are always low/high.</p>
<dl class="section return"><dt>Returns</dt><dd>Bounding interval </dd></dl>
<dl class="section see"><dt>See also</dt><dd><a class="el" href="class_qwt_o_h_l_c_sample.html#a5656375ea78ab080d53114ab80aa3934" title="Check if a sample is valid. ">isValid()</a> </dd></dl>

</div>
</div>
<a id="a5656375ea78ab080d53114ab80aa3934"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a5656375ea78ab080d53114ab80aa3934">&#9670;&nbsp;</a></span>isValid()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">bool QwtOHLCSample::isValid </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Check if a sample is valid. </p>
<p>A sample is valid, when all of the following checks are true:</p>
<ul>
<li>low &lt;= high</li>
<li>low &lt;= open &lt;= high</li>
<li>low &lt;= close &lt;= high</li>
</ul>
<dl class="section return"><dt>Returns</dt><dd>True, when the sample is valid </dd></dl>

</div>
</div>
<h2 class="groupheader">Member Data Documentation</h2>
<a id="a7d457c0a7d71f90539bf6233a19c1df4"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a7d457c0a7d71f90539bf6233a19c1df4">&#9670;&nbsp;</a></span>time</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">double QwtOHLCSample::time</td>
        </tr>
      </table>
</div><div class="memdoc">
<p>Time of the sample, usually a number representing a specific interval - like a day. </p>

</div>
</div>
</div><!-- contents -->
</div><!-- doc-content -->
<!-- start footer part -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
  <ul>
    <li class="navelem"><a class="el" href="class_qwt_o_h_l_c_sample.html">QwtOHLCSample</a></li>
    <li class="footer">Generated by
    <a href="http://www.doxygen.org/index.html">
    <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.8.14 </li>
  </ul>
</div>
</body>
</html>
